package com.example.service;

import com.example.entity.Building;
import com.example.entity.Page.PageRequest;
import com.example.entity.Page.PageResult;
import com.example.result.CommonResult;

/**
 * @project: smart-property
 * @description: 楼栋管理 service 层
 * @author: cjq
 * @create: 2022-11-17 15:23
 **/
public interface BuildingService {
    /**
     * 添加楼栋信息
     * @param building
     * @return
     */
    int saveBuildingInfo(Building building);

    /**
     * 小区楼座查重
     * @param cid
     * @param building
     * @return
     */
    CommonResult listBuildingName(Integer cid, String building);

    /**
     * 楼栋信息列表展示
     * @param purpose
     * @param building
     * @param pageRequest
     * @return
     */
    PageResult queryBuildingInfo(String purpose, String building, Integer cid,PageRequest pageRequest);

    /**
     * 删除楼栋信息
     * @param id
     * @return
     */
    int delBuildingInfo(Integer id);

    /**
     * 批量删除楼栋信息
     * @param ids
     * @return
     */
    int batchDel(Integer[] ids);
}
